package com.meilai.project.controller.web.business.workbench;

import com.meilai.project.dto.base.ApiResult;
import com.meilai.project.service.business.workbench.CompanyYearService;
import com.meilai.project.vo.business.workbench.CompanyYearTargetSummaryVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/api/web/company/year")
public class CompanyYearController {

    @Autowired
    private CompanyYearService service;

    @GetMapping("/queryCompanyYearTargetSummary")
    public ApiResult<CompanyYearTargetSummaryVO> queryCompanyYearTargetSummary(Integer year, Integer type) {
        return ApiResult.ok(service.queryCompanyYearTargetSummary(year, type));
    }
}
